<?php
/**
 * Created by PhpStorm.
 * User: s.utkin
 * Date: 15.01.2015
 * Time: 19:31
 */

namespace Menu;


class CheckAccessAction extends \Action {

	public function privileges() {
		$list = $this->request->privileges;

		if (!is_array($list)) {
			throw new \Exception('Empty privileges list.');
		}

		return $list;
	}

	protected function run()
	{
		$this->response->noRender(true);
		echo 'success';
	}
}